package com.wengzw.dao;

import com.wengzw.po.Customer;
import com.wengzw.vo.CustomerVo;
import org.apache.ibatis.annotations.*;
import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Repository;

import java.util.List;
@Repository
@Mapper
@Primary
public interface CustomerMapper {
    //查询客户列表


   List<Customer> findCustomerList(CustomerVo customerVo);

    //添加客户

    int addCustomer(Customer customer);

    //修改客户

    int updateCustomer(Customer customer);

    //删除客户
    int deleteById(Integer cust_id);

    //根据id查询用户
    @Select("select * from customer where cust_id = #{cust_id}")
    Customer findCustomerByID(Integer cust_id);

}